<?php

require_once '../../config/config.inc.php';
require_once _PS_ROOT_DIR_.'/init.php';

if (!is_array($_POST) || !isset($_POST['DATA']) || !strlen($_POST['DATA']))
	Tools::redirect('');

$response = $_POST['DATA'];

$dir = rtrim(dirname(__FILE__), '/');
$module = explode('/', $dir);
$module = $module[count($module)-1];
require_once $dir.'/'.$module.'.php';
$Module = new $module();

$Response = $Module->decryptResponse($response);
$Response->origin = 'silent_response';
$Module->processResponse($Response, $Customer, $Order);
header('HTTP/1.0 204 No Content');

?>